import request from "@/utils/request";

//拜访记录
export function handeldervisit(method, data) {
  if (method == "post") {
    return request({
      url: "/eldervisit",
      method: method,
      data,
    });
  } else {
    return request({
      url: "/eldervisit",
      method: method,
      params: data,
    });
  }
}

//外出记录
export function handelderwaichu(method, data) {
  if (method == "post") {
    return request({
      url: "/elderwaichu",
      method: method,
      data,
    });
  } else {
    return request({
      url: "/elderwaichu",
      method: method,
      params: data,
    });
  }
}


//搜索老人
export function eldersearch(method, data) {
  if (method == "post") {
    return request({
      url: "/elder/search",
      method: method,
      data,
    });
  } else {
    return request({
      url: "/elder/search",
      method: method,
      params: data,
    });
  }
}